#ifndef __EKOS_USER_MM_H__
#define __EKOS_USER_MM_H__

#include <types.h>

int   mm_init();

void *malloc(uint32_t size);
void  free(void *addr);

void *bmalloc(uint32_t size);
void  bfree(void *addr);

void *pmalloc(uint32_t size, int dma);
void  pfree(void *addr);

void *vmalloc(uint32_t size, physaddr_t addr);
void  vfree(void *addr);

void       self_mmap_set(uintptr_t vaddr, physaddr_t paddr, uint32_t flags);
physaddr_t self_mmap_get(uintptr_t vaddr, uint32_t *flags);

#define MMAP_W 1

void proc_set_data(void *data);
void *proc_get_data(void);

#endif
